﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Arcadia.Bookasa.Persistence.Facade;
using Arcadia.Bookasa.Persistence.Entity;

namespace Arcadia.Bookasa.Persistence.Dao
{
    public class SettingsDaoImpl : BaseDao, ISettingsDao
    {
        public Setting GetSetting(string name)
        {
            return CurrentSession.CreateCriteria(typeof(Setting))
                            .Add(NHibernate.Criterion.Restrictions.Eq("Name", name))
                            .UniqueResult<Setting>();
        }
    }
}
